#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
int main()
{
	int sum = 0;
	int num = 0;
	scanf("%d", &num);
	for (int i = 1; i < num; i++)
	{
		if (num % i == 0)
			sum += i;
	}
	if (num == sum)
		printf("Yes");
	else
		printf("No");
	return 0;
}